Previous topicNext topic
Help > Keyword Reference >
OR operator

Purpose

The OR operator works as both a logical and a bitwise arithmetic operator.

Syntax

p OR q

Remarks

Using OR as a logical operator

OR returns TRUE (non-zero) if and only if either or both of its operands is TRUE. Here is OR's truth table:

Truth table

x

y

x OR y

T

T

T

T

F

T

F

T

T

F

F

F

 

 

See also

Arithmetic Operators, AND, EQV, IMP, ISFALSE, ISTRUE, LET, NOT, XOR